{% extends '::base.html.twig' %}

{% block title %}Administration - Login{% endblock %}

{% block stylesheets %}
    <title>Administration - Login</title>
    <meta name="msapplication-TileColor" content="#5bc0de" />
    <meta name="msapplication-TileImage" content="" />
    
    <link rel="icon" type="image/png" href="{{ asset('bundles/jobhub/images/common/favicon.png') }}" />
    <!-- CSS -->
    <link href="{{ asset('bundles/jobhub/css/bootstrap.min.css') }}" rel="stylesheet" media="screen">
    <link href="{{ asset('bundles/jobhub/css/magic.min.css') }}" rel="stylesheet" media="screen">
    <link href="{{ asset('bundles/jobhub/css/main.css') }}" rel="stylesheet" media="screen">

    <!-- JS -->
    <script src="{{ asset('bundles/jobhub/js/bootstrap.min.js') }}" type="text/javascript"></script>
    <script src="{{ asset('bundles/jobhub/js/jquery-1.10.2.min.js') }}" type="text/javascript"></script>
    <script src="{{ asset('bundles/jobhub/js/main.js') }}" type="text/javascript"></script>
	
	<link rel="icon" type="image/x-icon" href="{{ asset('bundles/jobhub/images/logo_JobHub.png') }}" />
{% endblock %}

{% block body %}
<div class="login">
    <div class="container">
    
      <div class="text-center">
        <img src="{{ asset('bundles/jobhub/images/logo_JobHub.png') }}" alt="JobHub">
      </div>
      
      <div class="tab-content">
      <div id="login" class="tab-pane active">
		{# s'il y a une erreur #}  
		{% if error %}
			<p class="alert alert-error text-center"> Login ou mot de passe incorrect! Veuillez réessayer. </p>
		{% endif %}
		  <form action="{{ path('job_hub_administration_login_check') }}" class="form-signin" method="post">
			<p class="text-muted text-center">
			  Veuillez saisir votre login et mot de passe
			</p>            
			<input type="text"  name="_username" placeholder="Username" class="form-control" value="{{ last_username }}" />
			<input type="password" name="_password" placeholder="Password" class="form-control" /><br>
			<input class="btn btn-lg btn-primary btn-block" type="submit" value="Connexion">
		  </form>
	  </div>
        
      <div id="forgot" class="tab-pane">
          <form action="{{ path('job_hub_administration_login') }}" class="form-signin" method="post">
            <p class="text-muted text-center">Veuillez saisir votre adresse mailx</p>
            <input type="email" placeholder="mail@domain.com" required="required" class="form-control">
            <br>
            <button class="btn btn-lg btn-danger btn-block" type="submit">Réstituer le mot de passe</button>
          </form>
      </div>
      </div>
      
      <div class="text-center">
        <ul class="list-inline">
          <li> <a class="text-muted" href="#login" data-toggle="tab">Login</a> </li>
          <li> <a class="text-muted" href="#forgot" data-toggle="tab">Mot de passe oublié?</a> </li>
        </ul>
      </div>
    </div><!-- /container -->  
</div>
        
{% endblock %}
